package com.woniu.dao;

import com.woniu.domain.User;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiOperation;
import org.apache.ibatis.annotations.Param;

import java.util.List;
/**
 * @author: 刘家元  <br/>
 * Date: 2021/6/8:12:17  <br/>
 * Description:用户持久化接口
 */

public interface UsersDao {
    @ApiOperation(value = "根据角色id查询角色集合")
    @ApiImplicitParam(name = "roleId",value = "角色id")
    List<User> getByRoleId(@Param("roleId") Integer roleId) ;

    @ApiOperation(value = "根据姓名集合查询对应的角色信息")
    @ApiImplicitParam(name = "userName",value = "角色姓名集合")
    List<User> getUserByName(List<String> userName);

    @ApiOperation(value = "根据姓名集合修改对应的角色选课数量")
    @ApiImplicitParam(name = "userName",value = "角色姓名集合")
    int updateUserCourseNum(List<String> userName);

    @ApiOperation(value = "根据id修改对应的用户消息")
    @ApiImplicitParam(name = "user",value = "用户对象")
    int updateUserNews(User user);
}
